#ifndef _BSP_BACKLIGHT_H_
#define _BSP_BACKLIGHT_H_

#define CONFIG_HUD_BL_INTERVAL 333
#define CONFIG_HUD_BL_FREQ 2730
#define CONFIG_HUD_BL_DUTY 50
#define CONFIG_HUD_BL_COUNT 3

#define CONFIG_HUD_BL_TIMER MCPWM_TIMER_0
#define CONFIG_HUD_BL_UNIT MCPWM_UNIT_0
#define CONFIG_HUD_BL_SIGNAL MCPWM0A
#define CONFIG_HUD_BL_GPIO 22
#define CONFIG_HUD_BL_EN 19
#define CONFIG_HUD_BL_FAULT 21

#define CONFIG_HUD_BL_SLMAX 10
#define CONFIG_HUD_BL_SLMIN 5

#define GPIO_OUTPUT_IO 22

void bsp_backlight_init(void);
void bsp_backlight_start(void);
void bsp_backlight_stop(void);
void bsp_backlight_set_duty(float duty);
void bsp_backlight_calculate_set(float temp, float light, uint16_t brightness);

#endif